package com.ui.basic.assembler.administrative;

import java.util.List;

import com.common.basic.base.BaseAssembler;
import com.ui.basic.command.administrative.CommandExchangeRate;
import com.ui.basic.ibatis.model.admin.TblAExchangeRate;

public class ExchangeRateAssembler implements BaseAssembler<TblAExchangeRate, CommandExchangeRate> {

	public CommandExchangeRate toDto(TblAExchangeRate entity) {
		CommandExchangeRate dto = new CommandExchangeRate();
		dto.setId(entity.getId());
		dto.setDestCurrId(entity.getDestCurrId());
		dto.setSrcCurrId(entity.getSrcCurrId());
		dto.setRate(entity.getRate());
		dto.setCommission(entity.getCommission());
		return dto;
	}

	public List<CommandExchangeRate> toDtoList(List<TblAExchangeRate> listEntity) {
		return null;
	}

	public TblAExchangeRate toEntity(CommandExchangeRate dto) {
		TblAExchangeRate entity = new TblAExchangeRate();
		entity.setId(dto.getId());
		entity.setDestCurrId(dto.getDestCurrId());
		entity.setSrcCurrId(dto.getSrcCurrId());
		entity.setRate(dto.getRate());
		entity.setCommission(dto.getCommission());
		return entity;
	}

}
